<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="utf-8"/>
    <title>管理员菜单页面</title>
    <meta name="keywords" content="DeathGhost,DeathGhost.cn,web前端设,移动WebApp开发"/>
    <meta name="description" content="DeathGhost.cn::H5 WEB前端设计开发!"/>
    <meta name="author" content="DeathGhost"/>
    <link th:href="@{/style/style.css}" rel="stylesheet" type="text/css"/>
    <script type="text/javascript" th:src="@{/js/public.js}"></script>
    <script type="text/javascript" th:src="@{/js/jquery.js}"></script>
    <script type="text/javascript" th:src="@{/js/jqpublic.js}"></script>
    <script th:inline="javascript">
        window.onload = function() {
            var mm = [[${mm}]];
            if(mm != null){
                alert("添加成功")
            }
        }
    </script>
</head>
<body>
<!--引用头部导航栏代码块-->
<div th:replace="~{commons/common::top1}"></div>
<!--Start content-->
<section class="Psection MT20">
    <article class="U-article Overflow">
        <section class="fslist_navtree">
            <ul class="select">
                <li class="select-list">
                    <dl id="select1">
                        <dt>分类：</dt>
                        <dd th:if="${class0 eq '0'}" class="select-all selected"><a
                                th:href="@{'/admin/mealList?class0=0'}">全部</a></dd>
                        <dd th:if="${class0 ne '0'}"><a th:href="@{'/admin/mealList?class0=0'}">全部</a></dd>
                        <dd th:if="${class0 eq '1'}" class="select-all selected"><a
                                th:href="@{'/admin/mealList?class0=1'}">荤菜</a></dd>
                        <dd th:if="${class0 ne '1'}"><a th:href="@{'/admin/mealList?class0=1'}">荤菜</a></dd>
                        <dd th:if="${class0 eq '2'}" class="select-all selected"><a
                                th:href="@{'/admin/mealList?class0=2'}">素菜</a></dd>
                        <dd th:if="${class0 ne '2'}"><a th:href="@{'/admin/mealList?class0=2'}">素菜</a></dd>
                        <dd th:if="${class0 eq '3'}" class="select-all selected"><a
                                th:href="@{'/admin/mealList?class0=3'}">主食</a></dd>
                        <dd th:if="${class0 ne '3'}"><a th:href="@{'/admin/mealList?class0=3'}">主食</a></dd>
                        <dd th:if="${class0 eq '4'}" class="select-all selected"><a
                                th:href="@{'/admin/mealList?class0=4'}">饮品</a></dd>
                        <dd th:if="${class0 ne '4'}"><a th:href="@{'/admin/mealList?class0=4'}">饮品</a></dd>
                    </dl>
                </li>
            </ul>
            <input type="hidden" class="form-control" name="class0" id="class0" th:value="${class0}">
        </section>
        <!--user order list-->
        <section>
            <table class="Myorder">
                <th class="Font14 FontW">图片</th>
                <th class="Font14 FontW">名称</th>
                <th class="Font14 FontW">描述</th>
                <th class="Font14 FontW">原价</th>
                <th class="Font14 FontW">现价</th>
                <th class="Font14 FontW">售卖数量</th>
                <th class="Font14 FontW">类别</th>
                <th class="Font14 FontW">被收藏数量</th>
                <th class="Font14 FontW">操作</th>
                <tr th:each="meal:${mealList}">
                    <td class="FontW"><img width="50px" height="40px" th:src="${meal.meal_image}"/></td>
                    <td>[[${meal.meal_name}]]</td>
                    <td>[[${meal.meal_description}]]</td>
                    <td>[[${meal.meal_price}]]</td>
                    <td>[[${meal.meal_price_now}]]</td>
                    <td>[[${meal.meal_size}]]</td>
                    <td>[[${meal.meal_classification}]]</td>
                    <td>[[${meal.meal_collect}]]</td>
                    <td>
                        <a th:href="@{'/admin/adminqueryMealOne?meal_id='+${meal.meal_id}}" style="cursor:pointer;color: darkred;font-size: 15px;">修改&nbsp;</a>&nbsp;&nbsp;|&nbsp;&nbsp;
                        <a th:href="@{'/admin/adminqueryMealcart?meal_id='+${meal.meal_id}}" style="cursor:pointer;color: darkred;font-size: 15px;">查看评论</a>&nbsp;&nbsp;|&nbsp;&nbsp;
                        <a th:onclick="'remove_meal('+${meal.meal_id}+')'" style="cursor:pointer;color: darkred;font-size: 15px;">删除</a>
                    </td>
                </tr>
            </table>
            <div class="TurnPage">
                <a th:href="@{'/admin/mealList?pageNum='+${pageInfo.navigateFirstPage}+'&class0='+${class0}}">
                    <span class="Prev"><i></i>首页</span>
                </a>
                <a th:if="${pageInfo.pageNum != 1}" th:href="@{'/admin/mealList?pageNum='+${pageInfo.prePage}+'&class0='+${class0}}">
                    <span class="Prev">上一页<i></i></span>
                </a>
                <a th:if="${pageInfo.pageNum == 1}">
                    <span class="Prev">上一页<i></i></span>
                </a>
                <a th:if="${pageInfo.pageNum != pageInfo.pages}" th:href="@{'/admin/mealList?pageNum='+${pageInfo.nextPage}+'&class0='+${class0}}">
                    <span class="Next">下一页<i></i></span>
                </a>
                <a th:if="${pageInfo.pageNum == pageInfo.pages}">
                    <span class="Next">下一页<i></i></span>
                </a>
                <a th:href="@{'/admin/mealList?pageNum='+${pageInfo.navigateLastPage}+'&class0='+${class0}}">
                    <span class="Next">最后一页<i></i></span>
                </a>
                <span>
                当前第[[${pageInfo.pageNum}]]页&nbsp;&nbsp;&nbsp;共[[${pageInfo.pages}]]页
            </span>
            </div>
        </section>
    </article>
</section>
<!--End content-->
<!--引用底部栏代码块-->
<div th:replace="~{commons/common::last}"></div>
</body>
</html>
